package com.carrot.newsgallery.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.time.LocalDate;
import java.time.LocalDateTime;

@Data
@Api(value = "用户收藏")
public class NewsFavor {
    @ApiModelProperty(value = "自增主键")
    @TableId(value = "id", type = IdType.AUTO)
    private int newsFavorId;

    @ApiModelProperty(value = "所属用户的ID")
    private int userId;

    @ApiModelProperty(value = "新闻标题")
    private String title;
    @ApiModelProperty(value = "新闻来源榜单")
    private String source;
    @ApiModelProperty(value = "该新闻的当日排名")
    private int ranking;
    @ApiModelProperty(value = "新闻超链接")
    private String href;
    @ApiModelProperty(value = "新闻产生日期")
    private LocalDateTime gatherDate;
    @ApiModelProperty(value = "新闻收藏日期")
    private LocalDateTime favorDate;
    @ApiModelProperty(value = "公开日期")
    private LocalDateTime publicizeDate;

    @ApiModelProperty(value = "tag组成的字符串")
    @TableField(value = "tag")
    private String myTag;
    @ApiModelProperty(value = "用户笔记")
    private String note;

    @ApiModelProperty(value = "该笔记是否处于被分享的状态")
    private int isShared;
    @ApiModelProperty(value = "该笔记是否处于被封禁的状态")
    private int isBanned;

    @ApiModelProperty(value = "该笔记收获的赞的数量")
    private int favorNum;
    @ApiModelProperty(value = "该笔记拥有的评论数")
    private int commentNum;

}
